// 登录注册模块路由
const express = require('express');
const router = express.Router();
const loginHandler = require('../router_handle/login');
// 导入expressJOI
const expressJoi = require('@escook/express-joi');
// 导入验证规则
const { login_limit } = require('../limit/login');

// 注册
router.post('/register', expressJoi(login_limit), loginHandler.register)
// 登录
router.post('/login', expressJoi(login_limit), loginHandler.login)

// 返回路由列表
router.post('/returnMenuList', loginHandler.returnMenuList)

module.exports = router
